package com.etc.entity;
/**
 * 购物车的实体类
 * @author 
 *
 */
public class Shopc {
	/**
	 * shopcid 购物车Id
	 * userid 用户ID
	 * shopid 店铺ID
	 * goodsname  商品名称
	 * shopccount 下单量
	 * total  花费
	 * goodsid 商品编号
	 */
	private int shopcid;
	private int userid;
	private int shopid;
	private String goodsname;
	private int shopccount;
	private double total;
	private String shopname;
	
	private int goodsid;
	
	public int getGoodsid() {
		return goodsid;
	}
	public void setGoodsid(int goodsid) {
		this.goodsid = goodsid;
	}
	/**
	 * 
	 * @return the shopname
	 */
	public String getShopname() {
		return shopname;
	}
	/**
	 * @param shopname the shopname to set
	 */
	public void setShopname(String shopname) {
		this.shopname = shopname;
	}

	public Shopc(int userid, int shopid, String goodsname, int shopccount, double total, String shopname) {
		super();
		this.userid = userid;
		this.shopid = shopid;
		this.goodsname = goodsname;
		this.shopccount = shopccount;
		this.total = total;
		this.shopname = shopname;
	}
	
	//****************
	
	//无参构造
	public Shopc() {
		// TODO Auto-generated constructor stub
	}
	/**id自增的带参构造
	 * @param userid
	 * @param shopid
	 * @param goodsname
	 * @param shopccount
	 * @param total
	 */
	public Shopc(int userid, int shopid, String goodsname, int shopccount, double total) {
		super();
		this.userid = userid;
		this.shopid = shopid;
		this.goodsname = goodsname;
		this.shopccount = shopccount;
		this.total = total;
	}
	/**带参构造
	 * @param goodsid
	 * @param userid
	 * @param shopid
	 * @param goodsname
	 * @param shopccount
	 * @param total
	 */
	public Shopc(int goodsid, int userid, int shopid, String goodsname, int shopccount, double total) {
		super();
		this.goodsid = goodsid;
		this.userid = userid;
		this.shopid = shopid;
		this.goodsname = goodsname;
		this.shopccount = shopccount;
		this.total = total;
	}


	/**
	 * @return the shopcid
	 */
	public int getShopcid() {
		return shopcid;
	}


	/**
	 * @param shopcid the shopcid to set
	 */
	public void setShopcid(int shopcid) {
		this.shopcid = shopcid;
	}


	/**
	 * @return the userid
	 */
	public int getUserid() {
		return userid;
	}


	/**
	 * @param userid the userid to set
	 */
	public void setUserid(int userid) {
		this.userid = userid;
	}


	/**
	 * @return the shopid
	 */
	public int getShopid() {
		return shopid;
	}


	/**
	 * @param shopid the shopid to set
	 */
	public void setShopid(int shopid) {
		this.shopid = shopid;
	}


	/**
	 * @return the goodsname
	 */
	public String getGoodsname() {
		return goodsname;
	}


	/**
	 * @param goodsname the goodsname to set
	 */
	public void setGoodsname(String goodsname) {
		this.goodsname = goodsname;
	}


	/**
	 * @return the shopccount
	 */
	public int getShopccount() {
		return shopccount;
	}


	/**
	 * @param shopccount the shopccount to set
	 */
	public void setShopccount(int shopccount) {
		this.shopccount = shopccount;
	}


	/**
	 * @return the total
	 */
	public double getTotal() {
		return total;
	}


	/**
	 * @param total the total to set
	 */
	public void setTotal(double total) {
		this.total = total;
	}


	@Override
	public String toString() {
		return "购物车 [购物车id=" + shopcid + ", 用户id=" + userid + ", 商品id=" + shopid + ", 商品名称=" + goodsname
				+ ", 下单量=" + shopccount + ", 花费=" + total + "]";
	}
	
}
